<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ include file="../common.jsp" %>  
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>fileUpload</title>
</head>
<body>
	<table id="dg_file" fit="true"></table>
	<div id="toolbar">
		<form id="se" method="post">
				<table align="center">
					<tr>
						<td>文件名</td><td><input type="text"  size="11" id="fileName_"/></td>
				    	<td>类别</td><td><select id="fileType_" style="width:90px;">
					    	<option value="">请选择</option>
							<option value="通知公告">通知公告</option>
							<option value="公司政策">公司政策</option>
							<option value="技术资料">技术资料</option>
							<option value="宣传资料">宣传资料</option>
				    	</select></td>
					    <td><a  href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-search" onclick="sreach()">查询</a></td>
					    <td><a  href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-reload" onclick="refresh()">重置</a></td>
					</tr>
				</table>
		</form>
		<span id="span_1">
			<a href="javascript:void(0)" class="easyui-linkbutton" onclick="upload()" data-options="iconCls:'icon-add',plain:true">上传</a>
			<a href="javascript:void(0)" class="easyui-linkbutton" onclick="edit()" data-options="iconCls:'icon-edit',plain:true">编辑</a>
			<a href="javascript:void(0)" class="easyui-linkbutton" onclick="deleteFile('','','notFile')" data-options="iconCls:'icon-remove',plain:true">删除</a>
			<a href="javascript:void(0)" class="easyui-linkbutton" onclick="recycleBin()" id="recycle" data-options="iconCls:'icon-filter',plain:true">回收站</a>
		</span>
		<span id="span_2" style="display:none;">
			<a href="javascript:void(0)" class="easyui-linkbutton" onclick="goBack()" id="goBack" data-options="iconCls:'icon-back',plain:true">返回</a>
			<a href="javascript:void(0)" class="easyui-linkbutton" onclick="deleteFile('','','delFile')" id="goBack" data-options="iconCls:'icon-cancel',plain:true">彻底删除</a>
			<a href="javascript:void(0)" class="easyui-linkbutton" onclick="fileBack()" id="backFile" data-options="iconCls:'icon-undo',plain:true">还原</a>
		</span>
	</div>
	<div id="upload" style="width:400px;height:250px;">
		<form id="fileForm"  enctype="multipart/form-data" method="post">
			<div id="newUpload">
				<input type="file" name="file">
			</div><br><br>
			<label>文件类别:</label>
			<select name="fileType" id="fileType">
				<option value="">请选择</option>
				<option value="通知公告">通知公告</option>
				<option value="公司政策">公司政策</option>
				<option value="技术资料">技术资料</option>
				<option value="宣传资料">宣传资料</option>
			</select><br>
			<label>下载权限:</label>
			<select name="purview" id="purview">
				<option value="">请选择</option>
				<option value="0">所有人</option>
				<option value="1">基层职员</option>
				<option value="2">商务高层</option>
				<option value="3">管理员</option>
			</select><br>
			<input type="button" id="btn_add" value="增加一行" >
			<input type="button" value="上传"  onclick="upSubmit();">
		</form>
	</div>
	
	<form id="downloadForm" method="post" action="<%=basePath%>fileresource/download.do">
		<input type="hidden" name="fileName" id="fileName"/>
		<input type="hidden" name="url" id="url"/>
	</form>
<script type="text/javascript">
	var basePath = '<%=basePath%>';
</script>
<script type="text/javascript" src="<%=basePath%>resources/scripts/fileresource/fileindex.js"></script>
</body>
</html>